<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
    <style>
        .box {
            width: 300px;
            height: 400px;
            margin: 100px;
            border-radius: 10px;
            background: #fff;
            transition: 0.5s;
            overflow: hidden;
            position: relative;
        }

        .box:hover {
            transform: translateY(-5px);
            box-shadow: 2px 2px 20px #ccc;
        }

        .tip {
            height: 0px;
            width: 100%;
            position: absolute;
            bottom: 0px;
            background: orangered;
            transition: 0.5s;
        }

        .box:hover .tip {
            height: 50px;
        }
    </style>
</head>

<body style="background:#eee">
    <div class="box">
        <div class="tip">123131<br>31321</div>
    </div>
</body>

</html>